package com.itheima.dao;

import com.itheima.domain.UserInfo;
import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;
import org.springframework.stereotype.Repository;

import java.util.List;

public interface UserDao {
    //查询
    @Select("select * from account")
    public List<UserInfo> findAll();

    //新增
    @Insert("<script>insert into account(AccountName,remaining)" +
            "values(#{AccountName},#{remaining})</script>")
    public void insert( UserInfo userInfo);
}
